home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software Vault: The Gold Collection
/
Software Vault - The Gold Collection (American Databankers) (1993).ISO
/
cdr47
/
extmath.zip
/
EXTNEG.S
< prev
next >
Wrap
Text File
|
1993-01-06
|
621b
|
39 lines
; Negate 64-bit number
;
; Tim Victor, January 5, 1993
;
; Callable from C as follows:
; int ExtNeg(val);
; always return 0
;
.model small
.code
public _ExtNeg
_ExtNeg proc near
push si
mov si,sp
mov si,[si+4] ; source address
sub ax,ax
neg word ptr [si]
mov bx,ax
sbb bx,[si+2]
mov [si+2],bx
mov bx,ax
sbb bx,[si+4]
mov [si+4],bx
mov bx,ax
sbb bx,[si+6]
mov [si+6],bx
pop si
ret
_ExtNeg endp
end